\documentclass[letterpaper, 12pt]{article}

\usepackage{amsmath, amsthm, amsfonts, amssymb, bm}
\usepackage[title]{appendix}

\usepackage{booktabs}
\usepackage{multirow}
\usepackage[longnamesfirst]{natbib}
\usepackage[title]{appendix}
\usepackage{fullpage}
\usepackage{setspace}
\usepackage{graphicx}
\usepackage{enumitem}
\usepackage[labelfont=bf, font={small,it}]{caption}
\usepackage{subcaption}
\usepackage{tikz}
\usepackage{float}
\usepackage{mathtools}
\usepackage{array}
\usepackage{breakurl}
\usepackage{ragged2e}

\usepackage{sectsty}
\sectionfont{\fontsize{12}{12}\selectfont}
\subsectionfont{\fontsize{12}{12}\selectfont}

% Note: Best to have hyperref be the last package loaded
\usepackage[pagebackref=true,
				colorlinks=true,
%            linkcolor=red,
				linkcolor=black,
%            citecolor=blue,
				citecolor=black,
				bookmarks=true
				]{hyperref}
%\usepackage{refcheck}


%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Common math definitions
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\theoremstyle{definition}
\newtheorem{proposition}{Proposition}
\newtheorem{lemma}{Lemma}
\newtheorem{theorem}{Theorem}
\newtheorem{assumption}{Assumption}

\DeclareMathAlphabet\mathbb{U}{fplmbb}{m}{n} %Preferred style of \mathbb
\renewcommand{\qedsymbol}{\itshape Q.E.D.}
\newcommand{\re}{\mathbb{R}}
\newcommand{\reext}{\overline{\re}}

\DeclareMathOperator{\Cov}{Cov}
\DeclareMathOperator{\Corr}{Corr}
\DeclareMathOperator{\Exp}{\mathbb{E}}
\DeclareMathOperator{\Var}{Var}
\DeclareMathOperator{\Prob}{\mathbb{P}}
\DeclareMathOperator{\AsyVar}{AVar}
\DeclareMathOperator{\con}{con}
\DeclareMathOperator{\rng}{rng}
\DeclareMathOperator{\dom}{dom}
\DeclareMathOperator{\real}{Re}
\DeclareMathOperator{\diag}{diag}
\DeclareMathOperator{\imag}{Im}
\DeclareMathOperator{\interior}{int}
\DeclareMathOperator{\diameter}{diam}
\DeclareMathOperator{\range}{rng}
\DeclareMathOperator{\median}{med}
\DeclareMathOperator{\dimension}{dim}
\DeclareMathOperator{\trace}{tr}
\DeclareMathOperator{\rank}{rk}
\DeclareMathOperator{\std}{std}
\DeclareMathOperator{\sign}{sgn}
\DeclareMathOperator{\supp}{supp}
\DeclareMathOperator{\Trace}{Tr}
\DeclareMathOperator{\closure}{cl}
\DeclareMathOperator{\boundary}{bd}
\def\argmax{\operatornamewithlimits{arg\,max}}
\def\argmin{\operatornamewithlimits{arg\,min}}
\def\argsup{\operatornamewithlimits{arg\,sup}}
\def\arginf{\operatornamewithlimits{arg\,inf}}

\newcommand{\plim}{\mathchoice{\stackrel{\mathbb{P}}{\rightarrow}}{\rightarrow_\mathbb{P}}{\rightarrow_\mathbb{P}}{\rightarrow_\mathbb{P}}}
\newcommand{\dlim}{\mathchoice{\stackrel{d}{\rightarrow}}{\rightarrow_d}{\rightarrow_d}{\rightarrow_d}}
\newcommand{\aslim}{\mathchoice{\stackrel{as}{\rightarrow}}{\rightarrow_{as}}{\rightarrow_{as}}{\rightarrow_{as}}}
\newcommand{\Llim}[1]{\mathchoice{\stackrel{L_{#1}}{\rightarrow}}{\rightarrow_{L_{#1}}}{\rightarrow_{L_{#1}}}{\rightarrow_{L_{#1}}}}
\newcommand{\abs}[1]{\left\vert #1 \right\vert}
\newcommand{\absSmall}[1]{\vert #1 \vert}
\newcommand{\norm}[1]{\left\Vert #1 \right\Vert}
\newcommand{\normSmall}[1]{\Vert #1 \Vert}
\newcommand{\innerprod}[2]{\langle #1,#2 \rangle}
\newcommand{\Indic}[1]{\mathbb{1}\left[#1\right]}
\newcommand{\IndicSmall}[1]{\mathbb{1}[#1]}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Independence (perp with two bars)
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\newcommand\independenT{\protect\mathpalette{\protect\independeNT}{\perp}}
\def\independeNT#1#2{\mathrel{\rlap{$#1#2$}\mkern2mu{#1#2}}}
\DeclareMathOperator{\independent}{\independenT}
\DeclareMathOperator{\dependent}{\independenT \! \! \! \! \! \! \! \diagup}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\newcommand{\note}[1]{\textcolor{red}{\textbf{#1}}}
\newcommand{\muhat}{\hat{\mu}}
\newcommand{\muhatsc}{\hat{\mu}^{\text{sc}}}
\newcommand{\omegasc}{\omega^{\text{sc}}}
\newcommand{\muhatlo}{\hat{\mu}^{\text{lo}}}
\newcommand{\omegalo}{\omega^{\text{lo}}}
\newcommand{\muhatmatch}{\hat{\mu}^{\text{ma}}}
\newcommand{\omegamatch}{\omega^{\text{ma}}}
\newcommand{\muhatmasc}{\hat{\mu}^{\text{masc}}}
\newcommand{\omegamasc}{\omega^{\text{masc}}}
\newcommand{\muhatpen}{\hat{\mu}^{\text{pen}}}
\newcommand{\omegapen}{\omega^{\text{pen}}}
\newcommand{\simplex}{\mathcal{S}}
\newcommand{\M}{\mathcal{M}}
\newcommand{\F}{\mathcal{F}}
\newcommand{\trend}{\text{trend}}
\newcommand{\MSPE}{\text{MSPE}}

\newcommand{\SUBCAPWIDTH}{.9}


%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\def\MYTITLE{Computation of the MASC Estimator}

\def\MYKEYWORDS{synthetic control, matching, forecasting, cross-validation, program evaluation, causal inference, selection on observables, unconfoundedness}

\hypersetup{
    pdftitle = \MYTITLE,
    pdfkeywords = \MYKEYWORDS,
    pdfnewwindow = true
}

\title{\MYTITLE}

\author{
    Maxwell Kellogg\thanks{
        Department of Economics, University of Chicago.
    }
    \qquad
    Magne Mogstad\thanks{
        Department of Economics, University of Chicago; Statistics Norway; NBER.
    }\\[3mm]
    \;\,
    Guillaume A. Pouliot\thanks{
        Harris School of Public Policy, University of Chicago.
    }
    \qquad
    Alexander Torgovitsky\thanks{
        Department of Economics, University of Chicago.
        Research supported by National Science Foundation grant SES-1846832.
    }
}

\begin{document}

\maketitle


Given a treated unit treated in period $T$ and a set of control units,
The estimator $\hat{\mu}_t^{masc}$ fit to outcomes up to period $t, t<T$ is defined as:

$$\hat{\mu}_t^{masc}(\phi,m) \equiv \phi \hat{\mu}_t^{ma}(m) + (1-\phi)\hat{\mu}_t^{sc}$$

where $\hat{\mu}_t^{ma}(m)$ is an $m$-nearest neighbor estimator and  $\hat{\mu}_t^{sc}$
is a standard synthetic control estimator, both fit to the path of outcomes up to period $t$.
The model averaging parameter $\phi$ governs the weight placed on matching versus synthetic control,
$\phi \in [0,1]$.\

Our implementation uses a rolling-origin cross-validation procedure to  resolve the implicit
trade off between interpolation bias versus extrapolation bias in choosing the tuning parameters
$m$ and $\phi$. This involves making a series of one-step ahead forecasts, each of which is 
estimated only using data from periods prior to the forecast date. Mathematically, the criterion is:
$$Q(\phi,m) = \frac{1}{|\mathcal{F}|}\sum_{f \in \mathcal{F}} (y_{1,f+1} - \hat{\mu}_{f+1}^{masc}(\phi,m))^2 $$
where $y_{1,f+1}$ is the outcome of the treated unit in period $f+1$, and $\mathcal{F}$ is a subset of time periods
taken before the treatment period. There is a natural bias-variance trade off which drives the choice of folds $f$
to include in $\mathcal{F}$. Later periods are preferred because they will likely be more relevant to the post-treatment
period and will use more data. However, including earlier periods may reduce the variance in $Q(m,\phi)$. We recommend
that the analyst pick a cutoff value $f^*$, defining $\mathcal{F}$ to include all $f \ge f^*$ in the pre-treatment period.
The analyst must also choose the set of candidate nearest neighbor estimators from which to pick $m$.\

Computationally, we solve the cross-validation problem in two steps. First, we fix the candidate nearest neighbor estimator $m$.
Conditional on $m$, the cross-validation criterion has an analytic solution for $\phi$ using least square algebra:

$$\phi^*(m) = \frac{\sum_{f\in\mathcal{F}} (\hat{\mu}^{ma}_{f+1}(m)-\hat{\mu}^{sc}_{f+1})(y_{1,f+1}-\hat{\mu}_{f+1}^{sc})}{\sum_{f\in\mathcal{F}} (\hat{\mu}_{f+1}^{ma}(m)-\hat{\mu}_{f+1}^{sc})^2}$$

where the the real solution $\hat{\phi}(m)$ is then defined to respect the bounds on $\phi$:
\begin{align*}
\hat{\phi}(m)
\equiv
\begin{cases}
0, &\text{if } \phi^{\star}(m) \leq 0 \\
1, &\text{if } \phi^{\star}(m) \geq 1 \\
\phi^{\star}(m) &\text{otherwise}
\end{cases}
\end{align*}

For the second step, we then set $\hat{m} \equiv \underset{m}{\operatorname{argmin}} Q(\hat{\phi}(m),m)$ and set $\hat{\phi}=\hat{\phi}(\hat{m})$.
The cross-validated MASC estimator is a weighted average of $\hat{\mu}^{sc}_T$ and $\hat{\mu}^{ma}_T(\hat{m})$ with weights $(1-\hat{\phi})$
and $\hat{\phi}$ respectively.

\end{document}
